package com.su.gulimall.auth.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.ViewControllerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

@Configuration
public class MyWebConfig implements WebMvcConfigurer {
    @Override
    //视图跳转控制，可以借这个方法写假地址。
    //视图跳转控制默认请求方式为get，post的请求发送出现post not support 
    public void addViewControllers(ViewControllerRegistry registry) {
       /* registry.addViewController("/login.html").setViewName("login");
        registry.addViewController("/").setViewName("login");
        registry.addViewController("/index.html").setViewName("login");*/
        registry.addViewController("/register.html").setViewName("register");
    }
}
